import 'package:flutter/material.dart';

void main() =>runApp(MyApp(
//    items:new List<String>.generate(10, (i)=>"item+$i")


));

class MyApp extends StatelessWidget {

  final List<String> items;

  MyApp({Key key, @required this.items}) :super(key: key);


  @override
  Widget build(BuildContext context) {
    var card=new Card(
child: new Column(
  children: <Widget>[
    ListTile(
      title: new Text("我的家乡",style: TextStyle(fontSize: 16.0),),
      subtitle: Text("马夏龙15451215445454784"),
      leading: new Icon(Icons.access_alarm,color: Colors.pinkAccent,),
    ),
    new Divider(color: Colors.red,height: 10.0,),//分割线
    ListTile(
      title: new Text("我的家乡",style: TextStyle(fontSize: 16.0),),
      subtitle: Text("马夏龙15451215445454784"),
      leading: new Icon(Icons.access_alarm,color: Colors.pinkAccent,),
    ),
    ListTile(
      title: new Text("我的家乡",style: TextStyle(fontSize: 16.0),),
      subtitle: Text("马夏龙15451215445454784"),
      leading: new Icon(Icons.access_alarm,color: Colors.pinkAccent,),
    ),
    ListTile(
      title: new Text("我的家乡",style: TextStyle(fontSize: 16.0),),
      subtitle: Text("马夏龙15451215445454784"),
      leading: new Icon(Icons.access_alarm,color: Colors.pinkAccent,),
    ),
  ],
  
),
    );
    return MaterialApp(
        title: "Row Widgth demo",
        home: Scaffold(
            appBar: AppBar(
              title: Text("Card 布局"),
            ),
            body:Center(
              child: card,
            )
        )
    );
  }
}

class My4 extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return Row(
      children: <Widget>[
        RaisedButton(
          onPressed: (){

          },
          color: Colors.pinkAccent,
          child: Text("read")
          ,
        ),
        Expanded(child: RaisedButton(
          onPressed: (){
            print("wo kanakjn ");

          } ,
          color: Colors.lightBlue,
          child: Text("read1")
          ,
        )),
        Expanded(child: RaisedButton(
          onPressed: (){
            print("wo kanakjn ");

          } ,
          color: Colors.blueAccent,
          child: Text("read1")
          ,
        )),
        Expanded(child: RaisedButton(
          onPressed: (){
            print("wo kanakjn ");

          } ,
          color: Colors.pinkAccent,
          child: Text("read1")
          ,
        )),
        Expanded(child: RaisedButton(
          onPressed: (){
            print("wo kanakjn ");

          } ,
          color: Colors.pinkAccent,
          child: Text("read1")
          ,
        )),

      ],


    );
  }
}


class My3 extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return Row(
      children: <Widget>[

        RaisedButton(
          onPressed: (){
            print("wo kanakjn ");

          } ,
          color: Colors.pinkAccent,
          child: Text("read1")
          ,
        ),
        Expanded(child: RaisedButton(
          onPressed: (){
            print("wo kanakjn ");

          } ,
          color: Colors.pinkAccent,
          child: Text("read1")
          ,
        )),
        Expanded(child: RaisedButton(
          onPressed: (){
            print("wo kanakjn ");

          } ,
          color: Colors.pinkAccent,
          child: Text("read1")
          ,
        )),
        RaisedButton(
          onPressed: (){
            print("wo kanakjn ");

          } ,
          color: Colors.pinkAccent,
          child: Text("read1")
          ,
        ),

      ],


    );
  }
}